package com.winhxd.b2c.customer.dao;

import com.winhxd.b2c.common.domain.customer.condition.CustomerRevenueDetailCondition;
import com.winhxd.b2c.common.domain.customer.model.CustomerRevenueDetail;
import com.winhxd.b2c.common.domain.customer.vo.CustomerRevenueDetailVO;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * @author caiyulong
 */
@Repository
public interface CustomerRevenueDetailMapper {
    int deleteByPrimaryKey(Long id);

    int insert(CustomerRevenueDetail record);

    int insertSelective(CustomerRevenueDetail record);

    CustomerRevenueDetail selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(CustomerRevenueDetail record);

    int updateByPrimaryKey(CustomerRevenueDetail record);

    /**
     * 分销商/会员详情-收益日志
     * @author: wangbaokuo
     * @date: 2019/1/11 14:09
     * @param:
     * @return:
     */
    List<CustomerRevenueDetailVO> getUserRevenueDetail(CustomerRevenueDetailCondition condition);

    void batchInsert(@Param("customerRevenueDetails") List<CustomerRevenueDetail> customerRevenueDetails);

    List<CustomerRevenueDetail> selectListByOrderNo(@Param("orderNo") String orderNo);
}